package com.buba.pojo;

import com.buba.utils.MyCell;
import lombok.Data;

//1
@Data
public class UserInfo {
    @MyCell("编号")
    private String userId;
    @MyCell("姓名")
    private String userName;
    private String passWord;
    private Integer departId;
    @MyCell("性别")
    private Integer gender;
    private Integer roleId;
//    private Integer userState;

    private DepartInfo departInfo;//部门信息
    private Integer userStateId;
    private UserState userState;//状态
    @MyCell("部门")
    private String departInfoName;
    @MyCell("状态")
    private String userStateName;


    public void setDepartInfo(DepartInfo departInfo){
        this.departInfo = departInfo;
        if (departInfo != null)
            this.departInfoName = departInfo.getDepartName();
    }
    public void setUserState(UserState userState){
        this.userState = userState;
        if (userState != null)
            this.userStateName = userState.getUserStateName();
    }
}
